package com.cfk.shopmail.order.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.cfk.common.to.mq.SeckillOrderTo;
import com.cfk.common.utils.PageUtils;
import com.cfk.shopmail.order.entity.OrderEntity;
import com.cfk.shopmail.order.vo.*;

import java.util.Map;
import java.util.concurrent.ExecutionException;

/**
 * 订单
 *
 * @author fengyaowen
 * @email 983050705@qq.com
 * @date 2021-11-12 21:04:39
 */
public interface OrderService extends IService<OrderEntity> {

    PageUtils queryPage(Map<String, Object> params);

    //订单确认也返回需要的数据
    OrderConfirmVo confirmOrder() throws ExecutionException, InterruptedException;

    //下单
    SubmitOrderResponseVo submitOrder(OrderSubmitVo vo);

    OrderEntity getOrderByOrder(String orderSn);

    void closeOrder(OrderEntity entity);

    PayVo getOrderPay(String orderSn);

    PageUtils queryPageWithItem(Map<String, Object> params);

    void createSeckillOrder(SeckillOrderTo orderTo);

    // String handlePayResult(PayAsyncVo vo);
}

